package cn.xopencode.userservice.enums;

import cn.xopencode.common.framework.core.IntArrayValuable;

import java.util.Arrays;

/**
 * 政治面貌
 */
public enum PoliticalEnum implements IntArrayValuable {
    Political0(0, "未知"),
    Political1(1, "群众"),
    Political2(2, "党员"),
    Political3(3, "预备党员"),
    Political4(4, "团员");
    public static final int[] ARRAYS = Arrays.stream(values()).mapToInt(PoliticalEnum::getPolitical).toArray();

    /**
     * 政治面貌标识
     */
    private final Integer political;
    /**
     * 描述
     */
    private final String name;

    PoliticalEnum(Integer political, String name) {
        this.political = political;
        this.name = name;
    }

    public Integer getPolitical() {
        return political;
    }

    public String getName() {
        return name;
    }

    @Override
    public int[] array() {
        return ARRAYS;
    }

}
